using System;
using System.Collections.Generic;
using System.Text;
using System.Data;

namespace PhongKham.Controller
{
    class DSBenhNhanController
    {
        Class.ClsConnection ketnoi = new PhongKham.Class.ClsConnection();
        public DataSet GetAll()
        {
            return ketnoi.GetData("select * from BN_THONGTIN_BN");
        }

        public DataSet GetLike(String hoten)
        {
            return ketnoi.GetData("select * from BN_THONGTIN_BN where ten_bn like N'%"+ hoten+"%'");
        }

        public void UpdateDvitinh(DataTable table)
        {
            //ketnoi.Update(table, "select * from dm_dvitinh order by Ma_dvitinh", "dm_dvitinh");
        }

        public void InsertBN( String sql) {
            ketnoi.ExecuteNonQuery(sql);
        }
    }
}
